package com.cn.xiaonuo.slbfinances.slbreward.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.cn.xiaonuo.slbfinances.slbreward.entity.SlRewardRecord;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Mapper
@Repository
public interface CmRewardRecordMapper extends BaseMapper<String> {

    /*中获记录列表*/
    List<Map<String, Object>> getRewardList(@Param("phone") String phone, @Param("name") String name, @Param("start") Integer start, @Param("end") Integer end);

    /*获取有效订单用户信息*/
    List<Map<String, Object>> getValidOrderUsers(@Param("startDate") String startDate, @Param("start") Integer start, @Param("end") Integer end);

    /*批量插入中奖列表*/
    Integer insertRewardBatch(@Param("list") List<SlRewardRecord> list);
}
